#include"myshell.h"

#define SIZE 1024

extern char* myargv[ARGS];
extern int myargc;


void clean()
{
    for(size_t i = 0;i<myargc;i++)
    {
        myargv[i] = 0;
    }
    myargc = 0;
}

int main()
{
    char commandstring[SIZE] = {0};
    while(1)
    {    
         clean();
         PrintCommandString();
         if(!GetCommandString(commandstring,SIZE))
         {
             continue;
         }
         Check_redir(commandstring);
         PraseCommandString(commandstring);
         if(bulitin())
         {
             continue;
         }
         ForkExe(); 
    }


    
    return 0;
}
